const A = require('./A')
function average(num) {
    let sortNum = num.sort((x, y) => x - y)
    const surplus = sortNum.splice(1, sortNum.length - 2)
    return (A.sum(surplus) / surplus.length).toFixed(2)
}
module.exports = {
    average
} 